package cn.anlab.anappframe.demo.activity;

import android.os.Bundle;
import android.view.View;
import android.widget.LinearLayout;
import android.widget.TextView;
import cn.anlab.anappframe.BaseActivity;
import cn.anlab.anappframe.R;
import cn.anlab.anappframe.util.ViewUtil;

public class DimensActivity extends BaseActivity {
	
	private LinearLayout container;
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.demo_dimens);
		
		container = (LinearLayout) findViewById(R.id.linearLayout1);
		TextView tv;
		for(int i = 5; i < 30; i ++) 
		{
			tv = new TextView(this);
			tv.setText(i + "dip : " + "Hello World. 你好，世界！");
			tv.setTextSize(ViewUtil.dip2px(this, i));
			container.addView(tv);
		}
		
		
	}

}
